package svc

import (
	"github.com/zeromicro/go-zero/zrpc"
	"month2/B/api_B/internal/config"
	"month2/B/rpc_B/user"
	"month2/B/rpc_B/userclient"
)

type ServiceContext struct {
	Config config.Config
	BRpc   user.UserClient
}

func NewServiceContext(c config.Config) *ServiceContext {
	return &ServiceContext{
		Config: c,
		BRpc:   userclient.NewUser(zrpc.MustNewClient(c.BRpc)),
	}
}
